<!DOCTYPE html><html class="default" lang="en"><head><meta charSet="utf-8"/><meta http-equiv="x-ua-compatible" content="IE=edge"/><title>db-modeling-markdown</title><meta name="description" content="Documentation for db-modeling-markdown"/><meta name="viewport" content="width=device-width, initial-scale=1"/><link rel="stylesheet" href="assets/style.css"/><link rel="stylesheet" href="assets/highlight.css"/><script async src="assets/search.js" id="search-script"></script></head><body><script>document.documentElement.dataset.theme = localStorage.getItem("tsd-theme") || "os"</script><header class="tsd-page-toolbar">
<div class="tsd-toolbar-contents container">
<div class="table-cell" id="tsd-search" data-base=".">
<div class="field"><label for="tsd-search-field" class="tsd-widget search no-caption"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M15.7824 13.833L12.6666 10.7177C12.5259 10.5771 12.3353 10.499 12.1353 10.499H11.6259C12.4884 9.39596 13.001 8.00859 13.001 6.49937C13.001 2.90909 10.0914 0 6.50048 0C2.90959 0 0 2.90909 0 6.49937C0 10.0896 2.90959 12.9987 6.50048 12.9987C8.00996 12.9987 9.39756 12.4863 10.5008 11.6239V12.1332C10.5008 12.3332 10.5789 12.5238 10.7195 12.6644L13.8354 15.7797C14.1292 16.0734 14.6042 16.0734 14.8948 15.7797L15.7793 14.8954C16.0731 14.6017 16.0731 14.1267 15.7824 13.833ZM6.50048 10.499C4.29094 10.499 2.50018 8.71165 2.50018 6.49937C2.50018 4.29021 4.28781 2.49976 6.50048 2.49976C8.71001 2.49976 10.5008 4.28708 10.5008 6.49937C10.5008 8.70852 8.71314 10.499 6.50048 10.499Z" fill="var(--color-text)"></path></svg></label><input type="text" id="tsd-search-field" aria-label="Search"/></div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li></ul><a href="index.html" class="title">db-modeling-markdown</a></div>
<div class="table-cell" id="tsd-widgets"><a href="#" class="tsd-widget menu no-caption" data-toggle="menu" aria-label="Menu"><svg width="16" height="16" viewBox="0 0 16 16" fill="none"><rect x="1" y="3" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="7" width="14" height="2" fill="var(--color-text)"></rect><rect x="1" y="11" width="14" height="2" fill="var(--color-text)"></rect></svg></a></div></div></header>
<div class="container container-main">
<div class="col-8 col-content">
<div class="tsd-page-title">
<h2>db-modeling-markdown</h2></div>
<div class="tsd-panel tsd-typography">
<a href="#db-modeling-markdown-readme" id="db-modeling-markdown-readme" style="color: inherit; text-decoration: none;">
  <h1>db-modeling-markdown README</h1>
</a>
<p>Now, you may define your database tables in markdown files, and this utility will use them to generate .sql files.</p>
<ul>
<li><a href="http://sn-yang.gitee.io/db-modeling-markdown/">API Doc</a></li>
</ul>

<a href="#release-notes" id="release-notes" style="color: inherit; text-decoration: none;">
  <h2>Release Notes</h2>
</a>

<a href="#202" id="202" style="color: inherit; text-decoration: none;">
  <h3>2.0.2</h3>
</a>
<p><a href="./CHANGELOG.md">Change Log</a></p>

<a href="#samples" id="samples" style="color: inherit; text-decoration: none;">
  <h2>Samples</h2>
</a>
<p>Define a markdown file(.db.md) like：</p>
<pre><code class="language-markdown"><span class="hl-0"># Table: departments</span><br/><br/><span class="hl-0">## </span><span class="hl-1">`Table`</span><br/><br/><span class="hl-2">| </span><span class="hl-1">`Name`</span><span class="hl-2">      | </span><span class="hl-1">`Comment`</span><span class="hl-2">             | </span><span class="hl-1">`Character Set`</span><span class="hl-2"> | </span><span class="hl-1">`Collation`</span><span class="hl-2">        | </span><span class="hl-1">`Engine`</span><span class="hl-2"> |</span><br/><span class="hl-2">| ----------- | --------------------- | --------------- | ------------------ | -------- |</span><br/><span class="hl-2">| departments | The department table. | utf8mb4         | utf8mb4_general_ci | InnoDB   |</span><br/><br/><span class="hl-0">## </span><span class="hl-1">`Primary Key`</span><br/><br/><span class="hl-2">| </span><span class="hl-1">`Columns`</span><span class="hl-2">    |</span><br/><span class="hl-2">| ------------ |</span><br/><span class="hl-2">| DepartmentID |</span><br/><br/><span class="hl-0">## </span><span class="hl-1">`Indexes`</span><br/><br/><span class="hl-0">## </span><span class="hl-1">`Foreign Keys`</span><br/><br/><span class="hl-2">| </span><span class="hl-1">`Columns`</span><span class="hl-2"> | </span><span class="hl-1">`Ref Table`</span><span class="hl-2"> | </span><span class="hl-1">`Ref Columns`</span><span class="hl-2"> | </span><span class="hl-1">`Options`</span><span class="hl-2"> |</span><br/><span class="hl-2">| --------- | ----------- | ------------- | --------- |</span><br/><span class="hl-2">| ManagerID | employees   | EmployeeID    |           |</span><br/><span class="hl-2">| ParentID  | departments | DepartmentID  |           |</span><br/><br/><span class="hl-0">## </span><span class="hl-1">`Columns`</span><br/><br/><span class="hl-2">| </span><span class="hl-1">`Label`</span><span class="hl-2">         | </span><span class="hl-1">`Name`</span><span class="hl-2">         | </span><span class="hl-1">`Type`</span><span class="hl-2">                                 | </span><span class="hl-1">`Nullable`</span><span class="hl-2"> | </span><span class="hl-1">`Default`</span><span class="hl-2">           | </span><span class="hl-1">`Comment`</span><span class="hl-2">            |</span><br/><span class="hl-2">| --------------- | -------------- | -------------------------------------- | ---------- | ------------------- | -------------------- |</span><br/><span class="hl-2">| Department ID   | DepartmentID   | int auto_increment                     | </span><span class="hl-1">`No`</span><span class="hl-2">       |                     | Department ID        |</span><br/><span class="hl-2">| Department Name | DepartmentName | varchar(50)                            | </span><span class="hl-1">`No`</span><span class="hl-2">       |                     | Department Name      |</span><br/><span class="hl-2">| Parent ID       | ParentID       | int                                    | </span><span class="hl-1">`Yes`</span><span class="hl-2">      |                     | Parent Department    |</span><br/><span class="hl-2">| Manager ID      | ManagerID      | int                                    | </span><span class="hl-1">`Yes`</span><span class="hl-2">      |                     | Manager              |</span><br/><span class="hl-2">| Created By      | CreatedBy      | varchar(255)                           | </span><span class="hl-1">`No`</span><span class="hl-2">       | &#39;&#39;                  | Created By User Name |</span><br/><span class="hl-2">| Create Time     | CreateTime     | datetime                               | </span><span class="hl-1">`No`</span><span class="hl-2">       | current_timestamp() | Created Time         |</span><br/><span class="hl-2">| Update By       | UpdateBy       | varchar(255)                           | </span><span class="hl-1">`No`</span><span class="hl-2">       | &#39;&#39;                  | Updated By User Name |</span><br/><span class="hl-2">| Update Time     | UpdateTime     | datetime on update current_timestamp() | </span><span class="hl-1">`No`</span><span class="hl-2">       | current_timestamp() | Updated Time         |</span>
</code></pre>
<p>You will get SQL scripts:</p>
<pre><code class="language-sql"><span class="hl-3">-- Create table &#39;departments&#39;</span><br/><span class="hl-4">CREATE</span><span class="hl-2"> </span><span class="hl-4">TABLE</span><span class="hl-2"> </span><span class="hl-5">`departments`</span><span class="hl-2"> (</span><br/><span class="hl-2">    </span><span class="hl-5">`DepartmentID`</span><span class="hl-2"> </span><span class="hl-4">int</span><span class="hl-2"> auto_increment </span><span class="hl-4">NOT</span><span class="hl-2"> </span><span class="hl-4">NULL</span><span class="hl-2"> COMMENT </span><span class="hl-5">&#39;Department ID&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`DepartmentName`</span><span class="hl-2"> </span><span class="hl-4">varchar</span><span class="hl-2">(</span><span class="hl-6">50</span><span class="hl-2">) </span><span class="hl-4">NOT</span><span class="hl-2"> </span><span class="hl-4">NULL</span><span class="hl-2"> COMMENT </span><span class="hl-5">&#39;Department Name&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`ParentID`</span><span class="hl-2"> </span><span class="hl-4">int</span><span class="hl-2"> COMMENT </span><span class="hl-5">&#39;Parent Department&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`ManagerID`</span><span class="hl-2"> </span><span class="hl-4">int</span><span class="hl-2"> COMMENT </span><span class="hl-5">&#39;Manager&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`CreatedBy`</span><span class="hl-2"> </span><span class="hl-4">varchar</span><span class="hl-2">(</span><span class="hl-6">255</span><span class="hl-2">) </span><span class="hl-4">NOT</span><span class="hl-2"> </span><span class="hl-4">NULL</span><span class="hl-2"> </span><span class="hl-4">DEFAULT</span><span class="hl-2"> </span><span class="hl-5">&#39;&#39;</span><span class="hl-2"> COMMENT </span><span class="hl-5">&#39;Created By User Name&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`CreateTime`</span><span class="hl-2"> </span><span class="hl-4">datetime</span><span class="hl-2"> </span><span class="hl-4">NOT</span><span class="hl-2"> </span><span class="hl-4">NULL</span><span class="hl-2"> </span><span class="hl-4">DEFAULT</span><span class="hl-2"> </span><span class="hl-7">current_timestamp</span><span class="hl-2">() COMMENT </span><span class="hl-5">&#39;Created Time&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`UpdateBy`</span><span class="hl-2"> </span><span class="hl-4">varchar</span><span class="hl-2">(</span><span class="hl-6">255</span><span class="hl-2">) </span><span class="hl-4">NOT</span><span class="hl-2"> </span><span class="hl-4">NULL</span><span class="hl-2"> </span><span class="hl-4">DEFAULT</span><span class="hl-2"> </span><span class="hl-5">&#39;&#39;</span><span class="hl-2"> COMMENT </span><span class="hl-5">&#39;Updated By User Name&#39;</span><br/><span class="hl-2">  , </span><span class="hl-5">`UpdateTime`</span><span class="hl-2"> </span><span class="hl-4">datetime</span><span class="hl-2"> </span><span class="hl-4">on</span><span class="hl-2"> </span><span class="hl-4">update</span><span class="hl-2"> </span><span class="hl-7">current_timestamp</span><span class="hl-2">() </span><span class="hl-4">NOT</span><span class="hl-2"> </span><span class="hl-4">NULL</span><span class="hl-2"> </span><span class="hl-4">DEFAULT</span><span class="hl-2"> </span><span class="hl-7">current_timestamp</span><span class="hl-2">() COMMENT </span><span class="hl-5">&#39;Updated Time&#39;</span><br/><span class="hl-2">  , </span><span class="hl-4">PRIMARY</span><span class="hl-2"> </span><span class="hl-4">KEY</span><span class="hl-2"> (DepartmentID)</span><br/><span class="hl-2">) ENGINE=InnoDB </span><span class="hl-4">DEFAULT</span><span class="hl-2"> CHARSET=utf8mb4 COMMENT=</span><span class="hl-5">&#39;The department table.&#39;</span><br/><span class="hl-2">;</span>
</code></pre>

<a href="#sample-code" id="sample-code" style="color: inherit; text-decoration: none;">
  <h2>Sample Code</h2>
</a>
<pre><code class="language-typescript"><span class="hl-8">import</span><span class="hl-2"> </span><span class="hl-4">*</span><span class="hl-2"> </span><span class="hl-8">as</span><span class="hl-2"> </span><span class="hl-9">path</span><span class="hl-2"> </span><span class="hl-8">from</span><span class="hl-2"> </span><span class="hl-5">&#39;path&#39;</span><br/><br/><span class="hl-8">import</span><span class="hl-2"> { </span><span class="hl-9">DatabaseTypes</span><span class="hl-2">, </span><span class="hl-9">DbmOptions</span><span class="hl-2">, </span><span class="hl-9">DbmService</span><span class="hl-2"> } </span><span class="hl-8">from</span><span class="hl-2"> </span><span class="hl-5">&#39;../src&#39;</span><br/><br/><span class="hl-4">const</span><span class="hl-2"> </span><span class="hl-10">options</span><span class="hl-2">: </span><span class="hl-11">DbmOptions</span><span class="hl-2"> = </span><span class="hl-4">new</span><span class="hl-2"> </span><span class="hl-7">DbmOptions</span><span class="hl-2">()</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">database</span><span class="hl-2"> = </span><span class="hl-9">DatabaseTypes</span><span class="hl-2">.</span><span class="hl-9">mariadb</span><br/><br/><span class="hl-3">// Generate database modeling markdown files (.db.md) from a database</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">sourceFolder</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">`../../temp/tables/v1`</span><span class="hl-2">)</span><br/><span class="hl-8">await</span><span class="hl-2"> </span><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">fromDatabase</span><span class="hl-2">(</span><br/><span class="hl-2">    {</span><br/><span class="hl-2">        </span><span class="hl-9">databaseType:</span><span class="hl-2"> </span><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">database</span><span class="hl-2">,</span><br/><span class="hl-2">        </span><span class="hl-9">host:</span><span class="hl-2"> </span><span class="hl-5">&#39;127.0.0.1&#39;</span><span class="hl-2">,</span><br/><span class="hl-2">        </span><span class="hl-9">port:</span><span class="hl-2"> </span><span class="hl-6">3306</span><span class="hl-2">,</span><br/><span class="hl-2">        </span><span class="hl-9">user:</span><span class="hl-2"> </span><span class="hl-5">&#39;root&#39;</span><span class="hl-2">,</span><br/><span class="hl-2">        </span><span class="hl-9">password:</span><span class="hl-2"> </span><span class="hl-5">&#39;password&#39;</span><span class="hl-2">,</span><br/><span class="hl-2">        </span><span class="hl-9">database:</span><span class="hl-2"> </span><span class="hl-5">&#39;my-db&#39;</span><span class="hl-2">,</span><br/><span class="hl-2">    },</span><br/><span class="hl-2">    </span><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">sourceFolder</span><span class="hl-2">,</span><br/><span class="hl-2">    </span><span class="hl-4">true</span><span class="hl-2">,</span><br/><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a sql file with create-table-if-not-exists scripts</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">sourceFolder</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../tests/data/mariadb/tables&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/createTableIf.sql&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toCreateTableIfNotExistsSql</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a sql file with create-table scripts</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/createTable.sql&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toCreateTableSql</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a sql file with drop-table scripts</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/dropTable.sql&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toDropTableSql</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a sql file with drop-then-create-table scripts</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/dropThenCreateTable.sql&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toDropThenCreateTableSql</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a sql file with upgrade scripts</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">previousVersionFolder</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">`../tests/data/mariadb/tables/v1`</span><span class="hl-2">)</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/upgrade.sql&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toUpgradeSql</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a json file</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/model.json&#39;</span><span class="hl-2">)</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toJson</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Read table definition markdow files(.db.md), and produce a model object</span><br/><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">targetPath</span><span class="hl-2"> = </span><span class="hl-5">&#39;&#39;</span><br/><span class="hl-4">const</span><span class="hl-2"> </span><span class="hl-10">model</span><span class="hl-2"> = </span><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toModel</span><span class="hl-2">(</span><span class="hl-9">options</span><span class="hl-2">)</span><br/><span class="hl-3">// eslint-disable-next-line no-console</span><br/><span class="hl-9">console</span><span class="hl-2">.</span><span class="hl-7">log</span><span class="hl-2">(</span><span class="hl-10">JSON</span><span class="hl-2">.</span><span class="hl-7">stringify</span><span class="hl-2">(</span><span class="hl-9">model</span><span class="hl-2">, </span><span class="hl-4">null</span><span class="hl-2">, </span><span class="hl-6">2</span><span class="hl-2">))</span><br/><br/><span class="hl-3">// Generate database modeling markdown files (.db.md) from a model</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">toMarkdown</span><span class="hl-2">(</span><span class="hl-9">model</span><span class="hl-2">, </span><span class="hl-9">path</span><span class="hl-2">.</span><span class="hl-7">join</span><span class="hl-2">(</span><span class="hl-9">__dirname</span><span class="hl-2">, </span><span class="hl-5">&#39;../temp/tables&#39;</span><span class="hl-2">), </span><span class="hl-4">true</span><span class="hl-2">)</span><br/><br/><span class="hl-3">// Generate index.md from a model</span><br/><span class="hl-9">DbmService</span><span class="hl-2">.</span><span class="hl-7">genIndexFile</span><span class="hl-2">(</span><span class="hl-9">model</span><span class="hl-2">, </span><span class="hl-9">options</span><span class="hl-2">.</span><span class="hl-9">sourceFolder</span><span class="hl-2">)</span>
</code></pre>

<a href="#features" id="features" style="color: inherit; text-decoration: none;">
  <h2>Features</h2>
</a>
<ul>
<li><p>Support Databases</p>
<ul>
<li>DB2</li>
<li>MariaDB</li>
<li>MS SQL Server</li>
<li>MySQL</li>
<li>Oracle Database</li>
<li>PostgreSQL</li>
<li>SQLite</li>
</ul>
</li>
<li><p>Support generate SQL scripts of create tables.</p>
</li>
<li><p>Support generate SQL scripts of create tables if not exists.</p>
</li>
<li><p>Support generate SQL scripts of drop then create tables.</p>
</li>
<li><p>Support generate SQL scripts of drop tables.</p>
</li>
<li><p>Support generate SQL scripts of upgrade a database (mariadb/mysql only).</p>
</li>
<li><p>Support generate database definition markdown files from a database (mariadb/mysql only).</p>
</li>
<li><p>Support generate a json file of the database model.</p>
</li>
<li><p>Support generate an model object of the database model.</p>
</li>
<li><p>Support generate database definition markdown files from a database model (json).</p>
</li>
<li><p>Support generate <code>index.md</code> for a database model.</p>
</li>
</ul>

<a href="#contributing" id="contributing" style="color: inherit; text-decoration: none;">
  <h2>Contributing</h2>
</a>
<p>Please see <a href="./CONTRIBUTING.md">Contributing</a></p>
<p><strong>Enjoy!</strong></p>
</div></div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<div class="tsd-navigation settings">
<details class="tsd-index-accordion"><summary class="tsd-accordion-summary">
<h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></svg> Settings</h3></summary>
<div class="tsd-accordion-details">
<div class="tsd-filter-visibility">
<h4 class="uppercase">Member Visibility</h4><form>
<ul id="tsd-filter-options">
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-protected" name="protected"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Protected</span></label></li>
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-inherited" name="inherited" checked/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>Inherited</span></label></li>
<li class="tsd-filter-item"><label class="tsd-filter-input"><input type="checkbox" id="tsd-filter-external" name="external"/><svg width="32" height="32" viewBox="0 0 32 32" aria-hidden="true"><rect class="tsd-checkbox-background" width="30" height="30" x="1" y="1" rx="6" fill="none"></rect><path class="tsd-checkbox-checkmark" d="M8.35422 16.8214L13.2143 21.75L24.6458 10.25" stroke="none" stroke-width="3.5" stroke-linejoin="round" fill="none"></path></svg><span>External</span></label></li></ul></form></div>
<div class="tsd-theme-toggle">
<h4 class="uppercase">Theme</h4><select id="theme"><option value="os">OS</option><option value="light">Light</option><option value="dark">Dark</option></select></div></div></details></div>
<nav class="tsd-navigation primary">
<details class="tsd-index-accordion" open><summary class="tsd-accordion-summary">
<h3><svg width="20" height="20" viewBox="0 0 24 24" fill="none"><path d="M4.93896 8.531L12 15.591L19.061 8.531L16.939 6.409L12 11.349L7.06098 6.409L4.93896 8.531Z" fill="var(--color-text)"></path></svg> Modules</h3></summary>
<div class="tsd-accordion-details">
<ul>
<li class="current selected"><a href="modules.html">db-<wbr/>modeling-<wbr/>markdown</a>
<ul></ul></li></ul></div></details></nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul>
<li class="tsd-kind-enum"><a href="enums/DatabaseTypes.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-enum)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6" id="icon-8-path"></rect><path d="M9.45 16V7.24H14.49V8.224H10.518V10.936H14.07V11.908H10.518V15.016H14.49V16H9.45Z" fill="var(--color-text)" id="icon-8-text"></path></svg>Database<wbr/>Types</a></li>
<li class="tsd-kind-class"><a href="classes/DbmOptions.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-class)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6" id="icon-128-path"></rect><path d="M11.898 16.1201C11.098 16.1201 10.466 15.8961 10.002 15.4481C9.53803 15.0001 9.30603 14.3841 9.30603 13.6001V9.64012C9.30603 8.85612 9.53803 8.24012 10.002 7.79212C10.466 7.34412 11.098 7.12012 11.898 7.12012C12.682 7.12012 13.306 7.34812 13.77 7.80412C14.234 8.25212 14.466 8.86412 14.466 9.64012H13.386C13.386 9.14412 13.254 8.76412 12.99 8.50012C12.734 8.22812 12.37 8.09212 11.898 8.09212C11.426 8.09212 11.054 8.22412 10.782 8.48812C10.518 8.75212 10.386 9.13212 10.386 9.62812V13.6001C10.386 14.0961 10.518 14.4801 10.782 14.7521C11.054 15.0161 11.426 15.1481 11.898 15.1481C12.37 15.1481 12.734 15.0161 12.99 14.7521C13.254 14.4801 13.386 14.0961 13.386 13.6001H14.466C14.466 14.3761 14.234 14.9921 13.77 15.4481C13.306 15.8961 12.682 16.1201 11.898 16.1201Z" fill="var(--color-text)" id="icon-128-text"></path></svg>Dbm<wbr/>Options</a></li>
<li class="tsd-kind-class"><a href="classes/DbmService.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-128-path"></use><use href="#icon-128-text"></use></svg>Dbm<wbr/>Service</a></li>
<li class="tsd-kind-interface"><a href="interfaces/DbColumn.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><rect fill="var(--color-icon-background)" stroke="var(--color-ts-interface)" stroke-width="1.5" x="1" y="1" width="22" height="22" rx="6" id="icon-256-path"></rect><path d="M9.51 16V15.016H11.298V8.224H9.51V7.24H14.19V8.224H12.402V15.016H14.19V16H9.51Z" fill="var(--color-text)" id="icon-256-text"></path></svg>Db<wbr/>Column</a></li>
<li class="tsd-kind-interface"><a href="interfaces/DbForeignKey.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-256-path"></use><use href="#icon-256-text"></use></svg>Db<wbr/>Foreign<wbr/>Key</a></li>
<li class="tsd-kind-interface"><a href="interfaces/DbIndex.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-256-path"></use><use href="#icon-256-text"></use></svg>Db<wbr/>Index</a></li>
<li class="tsd-kind-interface"><a href="interfaces/DbModel.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-256-path"></use><use href="#icon-256-text"></use></svg>Db<wbr/>Model</a></li>
<li class="tsd-kind-interface"><a href="interfaces/DbPrimaryKey.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-256-path"></use><use href="#icon-256-text"></use></svg>Db<wbr/>Primary<wbr/>Key</a></li>
<li class="tsd-kind-interface"><a href="interfaces/DbTable.html" class="tsd-index-link"><svg class="tsd-kind-icon" width="24" height="24" viewBox="0 0 24 24"><use href="#icon-256-path"></use><use href="#icon-256-text"></use></svg>Db<wbr/>Table</a></li></ul></nav></div></div>
<div class="container tsd-generator">
<p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p></div>
<div class="overlay"></div><script src="assets/main.js"></script></body></html>